import os
from urllib import parse

BASE_DIR = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))

SERVER_HOST = '0.0.0.0'

pwd = 'Aa123456@#'
pwd = parse.quote_plus(pwd)

SQLALCHEMY_DATABASE_URI = 'mysql://root:{0}@47.98.210.232:3306/zzgdatabase?charset=utf8mb4'.format(pwd)

SECRET_KEY = '\x88D\xf09\x91\x07\x98\x89\x87\x96\xa0A\xc68\xf9\xecJ:U\x17\xc5V\xbe\x8b\xef\xd7\xd8\xd3\xe6\x98*4'

# 开启数据库查询性能测试
SQLALCHEMY_RECORD_QUERIES = True

# 性能测试的阀值
DATABASE_QUERY_TIMEOUT = 0.5

SQLALCHEMY_TRACK_MODIFICATIONS = True

WTF_CSRF_CHECK_DEFAULT = False

SQLALCHEMY_ECHO = True

